home *** CD-ROM | disk | FTP | other *** search
/ DarkBASIC - The Ultimate 3D Game Creator / PCactive 8 CD1 - DarkBasic.iso / SOFTWARE / DEMOS / DarkForge2000 / snippets_vol2 / snip_monitorglitch.dba < prev    next >
Encoding:
Text File  |  2000-08-18  |  981 b   |  48 lines

  1. `    ------------------------------------------------------------------------
  2. `    Who Broke My Monitor?!                     DarkForge Snippet (17/8/2000)
  3. `    ------------------------------------------------------------------------
  4. `
  5. `    This re-creates a superb monitor-glitch effect that looks like you've
  6. `    totally screwed with their video card! Of course it's 100% safe, don't
  7. `    panic. No photons were harmed in the production of this code.
  8. `    (well, maybe a few)
  9.  
  10. sync rate 0
  11. sync on
  12. hide mouse
  13.  
  14. `    s = the severity of the "glitch" !
  15. `    good values are 6, 32 and 64
  16.  
  17. s=6
  18.  
  19. load bitmap "anhk_inside.bmp",1
  20. create bitmap 2,640,480
  21.  
  22. set current bitmap 1
  23. for i=1 to 480
  24.     get image i,0,i-1,640,i
  25. next i
  26.  
  27. set text opaque
  28. ink rgb(255,255,255),0
  29.  
  30. do
  31.  
  32.     set current bitmap 2
  33.  
  34.     for i=1 to 480
  35.         paste image i,rnd(s),i
  36.     next i
  37.  
  38. `    Uncomment line below to display the FPS
  39. `    text 0,0,str$(screen fps())
  40.  
  41.     set current bitmap 0
  42.     copy bitmap 2,0
  43.  
  44.     sync
  45.  
  46. loop
  47.  
  48.